@import url("https://fonts.googleapis.com/css2?family=Rubik&display=swap");

/* variables */
:root {
  --primary: #22d0ff;
  --secondary: #0a0b5b;
}

/* reset */
body,
p,
a,
ul,
li {
  margin: 0;
  padding: 0;
  text-decoration: none;
}
li {
  list-style-type: none;
}

/* base styles */
body {
  background-color: var(--secondary);
  font-family: "Rubik", sans-serif;
  overflow-x: hidden;
}
.button {
  background: none;
  border: 2px solid var(--primary);
  color: var(--primary);
  padding: 6px 12px;
  border-radius: 20px;
  text-transform: uppercase;
  box-shadow: 1px 2px 3px rgba(0, 0, 0, 0.6);
  display: inline-block;
}
.button:hover {
  color: #222;
  background-color: var(--primary);
}
.button:active {
  outline: none;
}
input,
textarea {
  background-color: rgba(255, 255, 255, 0.05);
  color: #f2f2f2;
  padding: 10px 16px;
  border-radius: 20px;
  border: 2px solid #9893d8;
}

/* fonts */

h1,
h2,
h3,
h4 {
  color: #dddbff;
  font-weight: normal;
}
p,
a,
li {
  color: #9893d8;
}
h1,
h3 {
  font-size: 1.2em;
}
h2 {
  font-size: 1.6em;
}
h4 {
  font-size: 1.1em;
}
.leading {
  font-size: 1.1em;
}

/* MOBILE STYLES */
.grid {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 10px;
}

/* 1- nav section */
.site-nav {
  margin: 0 20px;
}
.site-nav ul {
  display: none;
}
.site-nav h1 {
  grid-column: 1/4;
  grid-row: 1;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--primary);
}

/* 2- hero section */
#welcome {
  padding: 0 20px 20px 20px;
}
.welcome-text {
  grid-column: 1/6;
}
.welcome-img {
  grid-column: 6/9;
}
.welcome-img img {
  width: 200%;
}
.welcome-text a {
  margin: 20px 0;
}

/* 3- portfolio section */
#portfolio {
  background: url(https://github.com/iamshaunjp/responsive-css-grid-build/blob/lesson-2/assets/square_bg.png?raw=true)
    bottom/cover no-repeat;
  padding: 30px 20px;
}
#portfolio h3 {
  text-align: center;
  margin-bottom: 0;
}
.projects a {
  grid-column: 1/9;
  margin: 20px 0;
  display: flex;
}
.projects a * {
  margin: 0 20px;
  max-width: 40%;
  align-self: center;
}
.projects h4 {
  color: #9994f7;
}

/* 4- skills section */
#skills {
  padding: 30px 20px;
  background-color: #07083e;
}
#skills h3 {
  text-align: center;
}
#skills ul {
  margin: 40px 0;
}
#skills li {
  padding: 10px;
  background-color: rgba(0, 0, 0, 0.2);
  grid-column: span 4;
  text-align: center;
}
#skills img {
  height: 80px;
  margin: 10px auto;
}

/* 5- contact section */
#contact {
  padding: 30px 20px;
  background: #080936;
}
#contact h3,
#contact p {
  text-align: center;
  margin-bottom: 0;
}
#contact form {
  width: 80%;
  max-width: 400px;
  margin: 20px auto;
  text-align: center;
}
#contact input,
#contact textarea {
  width: 100%;
  margin: 10px 0;
}
#contact .button {
  margin-top: 10px;
}

/* 6- footer section */
footer {
  padding: 30px 20px;
  background-color: #14153d;
  background-image: url(https://i.ibb.co/Fsc8R8H/satellite.png);
  background-size: 15%;
  background-repeat: no-repeat;
  background-position: bottom center;
}
footer .copyright {
  grid-column: 1/3;
  font-size: 0.8em;
}
footer .social {
  grid-column: 7/9;
  display: flex;
  justify-content: flex-end;
}
footer li {
  margin: 0 6px;
}
footer img {
  width: 20px;
}

/* SMALL TABLET STYLES */
@media screen and (min-width: 620px) {
  .welcome-text {
    grid-column: 1/5;
  }
  .welcome-img {
    grid-column: 5/9;
  }
  .welcome-img img {
    width: 100%;
  }

  .projects {
    margin-top: 40px;
  }
  .projects a {
    grid-column: span 4;
    display: block;
    margin: 20px 0;
  }
  .projects a:last-child {
    grid-column: 3/7;
  }
  .projects a * {
    max-width: 60%;
    margin: 10px 20%;
  }
  .projects h4 {
    text-align: center;
  }

  #skills {
    padding: 30px 100px;
  }

  footer {
    padding: 40px 10px;
    background-size: 11%;
  }
}

/* LARGE TABLET & LAPTOP STYLES */
@media screen and (min-width: 960px) {
  body {
    font-size: 1.125rem;
  }
  .grid {
    width: 100%;
    max-width: 1060px;
    margin: 0 auto;
    box-sizing: border-box;
  }

  .site-nav {
    padding: 0 20px;
  }
  .site-nav h1 {
    grid-column: 1/3;
  }
  .site-nav ul {
    display: flex;
    grid-column: 6/9;
    justify-content: flex-end;
    align-self: center;
  }
  .site-nav li {
    margin-left: 20px;
  }

  .welcome-text {
    align-self: center;
  }
  #welcome {
    padding-bottom: 40px;
  }
  .leading {
    margin: 20px 0;
  }

  .projects a:nth-child(1) {
    grid-column: 2/4;
  }
  .projects a:nth-child(2) {
    grid-column: 4/6;
    padding-top: 140px;
  }
  .projects a:nth-child(3) {
    grid-column: 6/8;
  }
  .projects a * {
    margin: 10px 10%;
    max-width: 80%;
  }

  #skills {
    padding: 30px 20px;
  }
  #skills ul {
    margin: 40px auto;
  }
  #skills li {
    grid-column: span 2;
  }

  footer {
    padding: 60px 20px;
  }
}

/* DESKTOP STYLES */
@media screen and (min-width: 1200px) {
  body {
    font-size: 1.25rem;
  }
  #welcome,
  #portfolio,
  #skills,
  #contact {
    padding: 90px 0;
  }

  .projects a:nth-child(1) {
    grid-column: 1/3;
  }
  .projects a:nth-child(3) {
    grid-column: 7/9;
  }
  .projects a * {
    margin: 30px 0;
    max-width: 100%;
  }

  footer {
    padding: 80px 0;
  }
  footer img {
    width: 30px;
  }
}
